import request from '@/utils/request'


export function addroom(data) {
    return request({
        url: '/api/app/smart-hotel-app-room/add-room',
        method: 'post',
        data
    })
}



export function getroom(params) {
    return request({
        url: '/api/app/smart-hotel-app-room/room',
        method: 'get',
        params: params
    })
}
export function gethouse() {
    return request({
        url: '/api/app/smart-hotel-app-house/house',
        method: 'get',
    })
}

export function deleteroom(id) {
    return request({
        url: `/api/app/smart-hotel-app-room/${id}/room`,
        method: 'delete',
        params: {
            id: id
        }
    })
}


export function getstate(id) {
    return request({
        url: `/api/app/smart-hotel-app-room/${id}/room-state`,
        method: 'get',
        params: {
            id: id
        }
    })
}
export function getfind(id) {
    return request({
        url: `/api/app/smart-hotel-app-room/${id}/find`,
        method: 'get',
        params: {
            id: id
        }
    })
}

export function updroom(data) {
    return request({
        url: '/api/app/smart-hotel-app-room/upd-room',
        method: 'put',
        data: data
    })
}